<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <title>人脸识别后台</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <link rel="stylesheet" href="__JS__/layui/css/layui.css" media="all">
    <link rel="stylesheet" href="__CSS__/font-awesome.min.css">
    <!--CSS引用-->
    {block name="css"}{/block}
    <link rel="stylesheet" href="__CSS__/admin.css">
    <!--[if lt IE 9]>
    <script src="__CSS__/html5shiv.min.js"></script>
    <script src="__CSS__/respond.min.js"></script>
    <![endif]-->
</head>
<script src="__JS__/jquery.min.js"></script>
<!-- 新订单提醒-s -->
<style type="text/css">
    .fl{ float:left; margin-left:10px;letter-spacing: 1.5px;font-size: 1rem;}
    .fr{ float:right; padding-right:10px; padding: 0 10px}
    .orderfoods{display: none; width:300px; border:1px solid #dedede; position:absolute; bottom:50px; z-index:999; right:10px; background-color:#1495E7;opacity:0.8;-webkit-opacity:0.8;filter:alpha(opacity=80);-moz-opacity:0.8;  }
    .dor_head{ border-bottom:1px solid #dedede; height:40px; line-height: 40px; color:#FFF; font-size:12px}
    .dor_head:after{ content:""; clear:both; display:block}
    .dor_foot{ padding: 10px 0; color:#FFF}
    .dor_foot p{ padding:0 12px}
    .te-in{ text-indent:2em;}
    .dor_foot p a {
        margin: 10px auto;
        display: block;
        background-color: #fff;
        width: 50%;
        padding: 3px 0;
        border-radius: 6px;
    }
    .dor_foot p span{ color: #f00;letter-spacing: 1.5px;}
    .dor_foot #orderAmount { font-size: 1.2rem;}
    .te-al-ce{ text-align:center}
</style>
<body>
<div class="layui-layout layui-layout-admin">
    <!--头部-->
    <div class="layui-header header">
        <a href=""><img class="logo" src="__STATIC__/images/admin_logo.png" alt=""></a>
        <ul class="layui-nav" style="position: absolute;top: 0;right: 20px;background: none;">
            <!--<li class="layui-nav-item"><a href="{:url('/')}" target="_blank">前台首页</a></li>-->
            <li class="layui-nav-item"><a href="" data-url="{:url('admin/system/clear')}" id="clear-cache">清除缓存</a></li>
            <li class="layui-nav-item">
                <a href="javascript:;">{:session('admin_name')}</a>
                <dl class="layui-nav-child"> <!-- 二级菜单 -->
                    <dd><a href="{:url('admin/change_password/index')}">修改密码</a></dd>
                    <dd><a href="{:url('admin/login/logout')}">退出登录</a></dd>
                </dl>
            </li>
        </ul>
    </div>

    <!--侧边栏-->
    <div class="layui-side layui-bg-black">
        <div class="layui-side-scroll">
            <ul class="layui-nav layui-nav-tree">
                <li class="layui-nav-item layui-nav-title"><a>管理菜单</a></li>
                <li class="layui-nav-item">
                    <a href="{:url('admin/index/index')}"><i class="fa fa-home"></i> 网站信息</a>
                </li>
                {foreach name="menu" item="vo"}
                {if condition="isset($vo['children'])"}
                <li class="layui-nav-item">
                    <a href="javascript:;"><i class="{$vo.icon}"></i> {$vo.title}</a>
                    <dl class="layui-nav-child">
                        {foreach name="vo['children']" item="v"}
                        <dd><a href="{:url($v.name)}"> {$v.title}</a></dd>
                        {/foreach}
                    </dl>
                </li>
                {else /}
                <li class="layui-nav-item">
                    <a href="{:url($vo.name)}"><i class="{$vo.icon}"></i> {$vo.title}</a>
                </li>
                {/if}
                {/foreach}

                <li class="layui-nav-item" style="height: 30px; text-align: center"></li>
            </ul>
        </div>
    </div>

    <!--主体-->
    {block name="body"}{/block}

    <!--底部-->
    <div class="layui-footer footer">
        <div class="layui-main">
            <p>2020-2120 &copy; <a href="https://www.maiguyun.com/" target="_blank">麦谷云</a></p>
        </div>
    </div>
</div>
<div id="ordfoo" class="orderfoods" style="">
    <div class="dor_head">
        <p class="fl">新通知</p>
        <p onClick="closes();" id="close" class="fr" style="cursor:pointer">x</p>
    </div>
    <input type="hidden" name="ids" >
    <div class="dor_foot">
        <p class="te-in">您有<span id="orderAmount"> 0 </span>个事务待处理</p>
        <p class="te-al-ce"  ><a  onclick="javascript:look2();" style="cursor:pointer" target='rightContent'><span>列表查看</span></a></p>
        <p class="te-al-ce"  ><a onclick="javascript:look();" style="cursor:pointer" target='_blank'><span>打印</span></a></p>
    </div>
</div>
<script>
    // 定义全局JS变量
    var GV = {
        current_controller: "admin/{$controller|default=''}/",
        current_action: "admin/{$action|default=''}/",
        base_url: "__STATIC__"
    };

    function ajaxOrderNotice(){
        var url = '{:url("User/ajaxUserNotice")}';
        $.ajax({
            type: "GET",
            url: url,
            // data: {username:$("#username").val(), content:$("#content").val()},
            dataType: "json",
            success: function(data){
                // console.log(data)
                if(data.num>0){
                    $('#orderAmount').text(data.num);

                     $("input[name='ids']").val(data.res[0])
                    $('#ordfoo').show();
                    // $('#orderAmount').text(data);
                    // if(document.getElementById('ordfoo').style.display == 'none'){
                    //     $('#orderAmount').text(data);
                    //     $('#ordfoo').show();
                    // }
                }
            }
        });
       setTimeout('ajaxOrderNotice()',5000);
    }
    setTimeout('ajaxOrderNotice()',5000);
    function look(){
        $('#ordfoo').hide();
        var id = $("input[name='ids']").val();
        window.open("/admin/user/edit/type/1/id/"+id+".html","_blank");
    }
    function look2(){
        $('#ordfoo').hide();
        var id = $("input[name='ids']").val();
        window.open("/admin/cuser/ch_index/type/2.html","_blank");
    }
    function closes(){
        $('#ordfoo').hide();
    }
</script>
<!--JS引用-->

<script src="__JS__/layui/lay/dest/layui.all.js"></script>
<script src="__JS__/admin.js"></script>
{block name="js"}{/block}
<!--页面JS脚本-->
{block name="script"}{/block}
</body>
</html>
